<?php

namespace App\Http\Controllers\user;

use App\Dao\OlisOrderDao;
use App\Exceptions\SysExceptions;
use App\Services\Code;

class OlisOrderController extends BaseController
{
    /**
     * @throws SysExceptions
     */
    public function add_order(): array
    {
        $params = array_merge([
            'user_id'=>getUserToken()
        ],request()->post());
        return Code::message('',200,OlisOrderDao::add_order($params));
    }


    public function oli_orders(): array
    {
        $params = array_merge([
            'user_id'=>getUserToken()
        ],request()->post());
        return Code::message('',200,OlisOrderDao::oli_orders($params));
    }
}
